<template>
  <div>
    <div class="box">
      <div class="login">
        <h2>在线教育后台管理系统</h2>

        <el-form
          :model="ruleForm"
          :rules="rules"
          ref="ruleForm"
          label-width="100px"
          class="demo-ruleForm"
        >
          <el-form
            :model="ruleForm"
            :rules="rules"
            ref="ruleForm"
            label-width="100px"
            class="demo-ruleForm"
          >
            <el-form-item prop="name">
              <el-input
                placeholder="请输入邮箱"
                prefix-icon="el-icon-user-solid"
                v-model="ruleForm.name"
                prop="name"
              >
              </el-input>
            </el-form-item>

            <el-form-item prop="password">
              <el-input
                placeholder="请输入密码"
                prefix-icon="el-icon-search"
                v-model="ruleForm.password"
                show-password
                prop="password"
              >
              </el-input>
            </el-form-item>
          </el-form>
        </el-form>
        <el-button type="primary">登录</el-button>
         <div class="sign">
        <div class="left">您还没有账户?</div>
        <div class="right" @click="goto"><a href="#">点击注册</a></div>
      </div>
      </div>
     
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      ruleForm: {
        name: "",
        password: "",
      },
      rules: {
        name: [
          { required: true, message: "您需要输入用户名", trigger: "blur" },
        ],
        password: [
          { required: true, message: "您需要输入密码", trigger: "blur" },
        ],
      },
    };
  },
  methods: {
    goto() {
        this.$router.push('/sign')
    }
  },
  created() {},
  mounted() {},
  components: {},
  computed: {},
  watch: {},
};
</script>

<style lang='scss' scoped>
.box {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100vw;
  height: 100vh;
  background-color: #2d3a4a;
}
.login {
  width: 500px;
  height: 300px;
  //   border: 1px solid #fff;
  h2 {
    margin-left: 170px;
    color: #fff;
    margin-bottom: 10px;
  }
  .el-button {
    width: 400px;
    height: 30px;
    text-align: center;
    line-height: 10px;
    margin-left: 100px;
  }
}
 .sign{
    width: 200px;
    height: 20px;
    // border: 1px solid #fff;
    margin: 10px 0 0 315px;
    color: #fff;
    .left{
        float: left;
        width: 120px;
    }
    .right{
        float: right;
        width: 80px;
        a{
            color: #fff;
            text-decoration: underline;
        }
    }
 }
</style>
